Electrical switches are limited in that switch outputs are susceptible to false readings due to noise, bounce, or other causes. For example, contacts of mechanical switches may open and close as the contacts bounce after the switch is triggered from one state to another. The resulting switch output may be interpreted as multiple activations of the switch or may otherwise result in undesired readings. Other types of switches, such as capacitive touch switches, do not have mechanical moving contacts that bounce but are still susceptible to inaccurate outputs due to other causes such as noise. Electro-magnetic signals and static electricity, for example, may cause the charge in a capacitive touch switch to discharge more rapidly or more slowly than otherwise and may cause the sensing circuitry to incorrectly interpret the state of the switch. Conventional techniques for dealing with switch bounce and noise, however, are limited in that additional hardware components are required, adding size and expense. Further, fixed timing must be established and the information regarding the switch output must be tracked, increasing complexity and consuming resources. For example, many conventional techniques for addressing switch bounce and noise issues include obtaining multiple samples of the switch output at periodic intervals to verify that the switch output signal was stable and was not the result of a transient. Typically, such a software solution is paired with an external hardware element such as a resistor-capacitor (R/C) filter.
Therefore, there is a need for a switch de-bouncing device and method.